package com.mall.czlr.base.common;

import lombok.Getter;

@Getter
public class PageObj {
    private Integer page;
    private Integer limit;

    PageObj() {
        this.page = 1;
        this.limit = Const.PAGE_LIMIT;
    }

    public void setPage(Integer page) {
        this.page = page < 1 ? 1 : page;
    }

    public void setLimit(Integer limit) {
        this.limit = limit != null ? limit : Const.PAGE_LIMIT;
    }
}
